Handling HSI_CardioMetabolicDisorders_Refill_Medication with climate disruptions. #1750
Handling HSI_CardioMetabolicDisorders_Refill_Medication with climate disruptions. #1750RachelMurray-Watson wants to merge 3 commits intomasterfrom
Conversation
…_Refill_Medication, there is a redone did_not_run function and new never_ran function. These share logic in that, if an appointment to refill medication does not go ahead due to climate,the person will come off of medication but restart it with a certain probability. If the appointment goes ahead, it is rescheduled with a delay that is set by a climate-delay parameter used in the healthcare system. Also added a check to ensure that the weightloss appointment cannot be scheduled if the person is already on weightloss treatment. (Concern - is there a more current check to see if someone is currently on weightloss treatment?) Also included changes in the healthcare system that are in the PR #1604 for illustration of how it would work. So far, only HSI_CardioMetabolicDisorders_Refill_Medication has the weather-related did_not_run and never_ran.
|
|
||
| def did_not_run(self): | ||
| # If this HSI event did not run, then the persons ceases to be taking medication | ||
| def did_not_run_weather_event(self): |
There was a problem hiding this comment.
I'm not sure it's worth renaming - this would either require, in the HealthSystem, you checking whether it is the appropriate CMD before calling did_not_run_weather_event, or ensuring that the did_not_run fnc in every HSI in the model is renamed did_not_run_weather_event
There was a problem hiding this comment.
this also applies to never ran
There was a problem hiding this comment.
As discussed: there is logic in the call_and_record_weather events that checks for CMD-related HSIs. Clunky, but functional for the moment!
There was a problem hiding this comment.
This delay should inform topen, not tclose; it would also be best if it could directly reference a function computing the climate delay, rather than being hardcoded
There was a problem hiding this comment.
You can keep the tclose - topen time gap as is usually coded when sheduling HSI_CardioMetabolicDisorders_StartWeightLossAndMedication
There was a problem hiding this comment.
These comments also apply to never_ran below
| # number of days of climate disruption | ||
| priority=1 | ||
| ) | ||
| def never_ran_weather_event(self): |
There was a problem hiding this comment.
it seems very odd that did_not_run and never_ran are identical. But I guess this makes sense since in the CMD any delay in care is equivalent to a complete cancellation...
| @@ -12,9 +12,11 @@ | |||
|
|
|||
| import numpy as np | |||
| import pandas as pd | |||
| from numpy import random | |||
There was a problem hiding this comment.
Not sure I follow why there are so many changes to the healthsystem in this PR?
There was a problem hiding this comment.
As discussed: out of date with master
…The tclose is 15 days after the new topen, in line with original reseeking healthcare logic.
A proposed fix for Issue 1748 (#1748), specifically for how the rescheduling of appointments works with weather disruptions.
In this, for HSI_CardioMetabolicDisorders_Refill_Medication, if did_not_run_weather_event or never_ran_weather_event are called, there is a certain probability the individual will restart treatment. If so, the HSI HSI_CardioMetabolicDisorders_StartWeightLossAndMedication is scheduled.
Also fixed error that allows multiple CardioMetabolicDisordersWeightLossEvent to be scheduled (as no check was on to see if individuals were ever on weight loss treatment).